/*--------------------------------------------------------------------------
    This source file is part of Abraxas Game Engine
    For the latest info, see http://code.google.com/abraxasge/
    Copyright (C) 2009, Andrew LeRoy <aleroy@member.igda.org>
    ---

    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    as published by the Free Software Foundation; either version 2
    of the License, or (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 51 Franklin Street, Fifth Floor,
    Boston, MA  02110-1301, USA.
--------------------------------------------------------------------------*/
#include "AbxGraphicsSystem.hpp"


namespace Abx
{
    //---------------------------------------------------------------------
    String const DefaultGraphicsSystemFactory::FACTORY_TYPE = "DefaultGraphicsSystem";
    //---------------------------------------------------------------------

    DefaultGraphicsSystemFactory::DefaultGraphicsSystemFactory()
    { }
    //---------------------------------------------------------------------

    DefaultGraphicsSystemFactory::~DefaultGraphicsSystemFactory()
    { }
    //---------------------------------------------------------------------

    GraphicsSystem* DefaultGraphicsSystemFactory::createInstance(String const& name)
    {
        DefaultGraphicsSystem* gfx = new DefaultGraphicsSystem(name);
        gfx->typeName_ = FACTORY_TYPE;
        return gfx;
    }
    //---------------------------------------------------------------------

    void DefaultGraphicsSystemFactory::destroyInstance(GraphicsSystem* instance)
    {
        delete instance;
    }
    //---------------------------------------------------------------------

    void DefaultGraphicsSystemFactory::initOptions() const
    {
        this->options_.typeName = FACTORY_TYPE;
        this->options_.description = "AbraxasGE default graphics system";
    }
    //---------------------------------------------------------------------





    DefaultGraphicsSystem::DefaultGraphicsSystem(String const& name)
        : GraphicsSystem(name)
    { }
    //---------------------------------------------------------------------

    DefaultGraphicsSystem::~DefaultGraphicsSystem()
    { }
    //---------------------------------------------------------------------

    String const& DefaultGraphicsSystem::getName() const
    {
        return this->name_;
    }
    //---------------------------------------------------------------------

    String const& DefaultGraphicsSystem::getTypeName() const
    {
        return typeName_;
    }
    //---------------------------------------------------------------------
} // namespace Abx
